package com.snline.crm.logistics.service;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.snline.crm.logistics.dao.inter.IUserMapper;
import com.snline.crm.logistics.entity.ProjectDetails;
import com.snline.crm.logistics.entity.ProjectUserInfo;

/**
 * 项目信息
 * @author admin
 *
 */
@Service("userService")
public class UserService{

	@Resource
	private IUserMapper userMapper;

	/**
	 * 用户的取得
	 * @param user 用户信息
	 * @return 用户信息
	 */
	public ProjectUserInfo findProjectUserInfoById(String userId) {

	    return userMapper.selectProjectUserInfoById(userId);
	}

	/**
	 * 用户的取得
	 * @param user 用户信息
	 * @return 用户信息
	 */
	public List<ProjectDetails> findAllUserInfo() {
	    return userMapper.selectAllUser();
	}
	
    /**
     * 项目信息修改
     * @param project 项目信息
     * @return 项目信息
     */
    public int updateProjectUserInfo(ProjectUserInfo projectUserInfo){

        return userMapper.updateProjectUserInfo(projectUserInfo);
    }

	/**
	 * @return the userMapper
	 */
	public IUserMapper getUserMapper() {
		return userMapper;
	}

	/**
	 * @param userMapper the userMapper to set
	 */
	public void setUserMapper(IUserMapper userMapper) {
		this.userMapper = userMapper;
	}
	
}
